const Sequelize = require('sequelize');
module.exports = function(sequelize, DataTypes) {
  return sequelize.define('base_standard_projectbidinfo', {
    id: {
      autoIncrement: true,
      type: DataTypes.INTEGER,
      allowNull: false,
      primaryKey: true,
      comment: "编号"
    },
    keyguid: {
      type: DataTypes.STRING(50),
      allowNull: true,
      comment: "键名"
    },
    rightcode: {
      type: DataTypes.INTEGER,
      allowNull: true,
      comment: "组织机构代码"
    },
    title: {
      type: DataTypes.STRING(200),
      allowNull: true,
      comment: "标题"
    },
    prjnum: {
      type: DataTypes.STRING(50),
      allowNull: true,
      comment: "项目编号"
    },
    tendernum: {
      type: DataTypes.STRING(50),
      allowNull: true,
      comment: "招投标编号"
    },
    tenderclassnum: {
      type: DataTypes.STRING(50),
      allowNull: true,
      comment: "招投标属性编号"
    },
    tenderresultdate: {
      type: DataTypes.DATE,
      allowNull: true,
      comment: "招投标结束日期"
    },
    tendermoney: {
      type: DataTypes.DECIMAL(15,4),
      allowNull: true,
      comment: "中标金额"
    },
    prjsize: {
      type: DataTypes.STRING(500),
      allowNull: true,
      comment: "项目规模"
    },
    area: {
      type: DataTypes.DECIMAL(15,4),
      allowNull: true,
      comment: "面积"
    },
    econcorpname: {
      type: DataTypes.STRING(200),
      allowNull: true,
      comment: "中标公司名称"
    },
    econcorpcode: {
      type: DataTypes.STRING(40),
      allowNull: true,
      comment: "中标编码"
    },
    tendercorpname: {
      type: DataTypes.STRING(200),
      allowNull: true,
      comment: "投标公司名称"
    },
    tendercorpcode: {
      type: DataTypes.STRING(40),
      allowNull: true,
      comment: "投标公司组织机构代码"
    },
    idcardtypenum: {
      type: DataTypes.STRING(50),
      allowNull: true,
      comment: "身份证属性编号"
    },
    tenderempname: {
      type: DataTypes.STRING(50),
      allowNull: true,
      comment: "投标人名称"
    },
    constructoridcard: {
      type: DataTypes.STRING(30),
      allowNull: true,
      comment: "建筑师身份证号"
    },
    registerdate: {
      type: DataTypes.DATE,
      allowNull: true,
      comment: "登记日期"
    },
    createtime: {
      type: DataTypes.DATE,
      allowNull: true,
      comment: "登记时间"
    },
    lastupdatetime: {
      type: DataTypes.DATE,
      allowNull: true,
      comment: "上次修改时间"
    },
    lastsynctime: {
      type: DataTypes.DATE,
      allowNull: true,
      comment: "上次同步时间"
    },
    stguid: {
      type: DataTypes.STRING(50),
      allowNull: true,
      comment: "标识id"
    },
    flowcode: {
      type: DataTypes.STRING(50),
      allowNull: true,
      comment: "生产规范"
    },
    dtidset: {
      type: DataTypes.STRING(500),
      allowNull: true
    },
    buildcorpname: {
      type: DataTypes.STRING(200),
      allowNull: true,
      comment: "建筑工地名称"
    },
    buildcorpcode: {
      type: DataTypes.STRING(40),
      allowNull: true,
      comment: "建筑公司统一机构编码"
    },
    builder: {
      type: DataTypes.STRING(20),
      allowNull: true,
      comment: "建筑工地"
    },
    buildertel: {
      type: DataTypes.STRING(50),
      allowNull: true,
      comment: "工地地址"
    },
    buildcorpaddress: {
      type: DataTypes.STRING(200),
      allowNull: true,
      comment: "工地地址"
    },
    isallowsync: {
      type: DataTypes.BOOLEAN,
      allowNull: true,
      comment: "是否允许同步"
    },
    tenderempzgzs: {
      type: DataTypes.STRING(200),
      allowNull: true
    },
    projectgq: {
      type: DataTypes.STRING(50),
      allowNull: true,
      comment: "项目工期"
    },
    zlmb: {
      type: DataTypes.STRING(200),
      allowNull: true
    },
    qualificationlevoftendercorp: {
      type: DataTypes.STRING(500),
      allowNull: true,
      comment: "公司资质"
    },
    areaflag: {
      type: DataTypes.INTEGER,
      allowNull: true,
      comment: "中标面积"
    },
    sourceid: {
      type: DataTypes.INTEGER,
      allowNull: true,
      comment: "起始id"
    },
    prjfinishnum: {
      type: DataTypes.STRING(20),
      allowNull: true,
      comment: "项目完成编号"
    },
    finishdate: {
      type: DataTypes.DATE,
      allowNull: true,
      comment: "完成日期"
    },
    issync: {
      type: DataTypes.BOOLEAN,
      allowNull: true,
      comment: "是否同步"
    },
    classid: {
      type: DataTypes.INTEGER,
      allowNull: true,
      comment: "属性id"
    },
    startdate: {
      type: DataTypes.DATEONLY,
      allowNull: true,
      comment: "开始日期"
    },
    enddate: {
      type: DataTypes.DATEONLY,
      allowNull: true,
      comment: "结束日期"
    },
    builderlicencenum: {
      type: DataTypes.STRING(50),
      allowNull: true,
      comment: "建筑许可证编号"
    },
    tenderemptel: {
      type: DataTypes.STRING(50),
      allowNull: true,
      comment: "中标电话"
    },
    areacode: {
      type: DataTypes.STRING(6),
      allowNull: true,
      comment: "起始面积"
    },
    bstatus: {
      type: DataTypes.INTEGER,
      allowNull: true,
      comment: "等级"
    },
    zbbidguid: {
      type: DataTypes.STRING(50),
      allowNull: true,
      comment: "招标信息ID"
    },
    changeflowstatus: {
      type: DataTypes.INTEGER,
      allowNull: true,
      comment: "变更人等级"
    },
    tendercorpdetailname: {
      type: DataTypes.STRING(100),
      allowNull: true,
      comment: "投标公司详细名称"
    },
    buildcorpdetailname: {
      type: DataTypes.STRING(100),
      allowNull: true,
      comment: "建筑公司详细名称"
    },
    econcorpdetailname: {
      type: DataTypes.STRING(100),
      allowNull: true,
      comment: "中标公司详细名称"
    },
    jgdtidset: {
      type: DataTypes.STRING(50),
      allowNull: true
    },
    dlxmzg: {
      type: DataTypes.STRING(50),
      allowNull: true
    },
    dlxmjbr: {
      type: DataTypes.STRING(50),
      allowNull: true
    },
    dlxmzgidcard: {
      type: DataTypes.STRING(50),
      allowNull: true
    },
    dlxmjbridcard: {
      type: DataTypes.STRING(50),
      allowNull: true
    },
    isdzyzproject: {
      type: DataTypes.BOOLEAN,
      allowNull: true
    },
    memo: {
      type: DataTypes.STRING(200),
      allowNull: true
    },
    startbidtime: {
      type: DataTypes.DATE,
      allowNull: true,
      comment: "开始时间"
    },
    shguid: {
      type: DataTypes.STRING(50),
      allowNull: true
    },
    shsynctime: {
      type: DataTypes.DATE,
      allowNull: true
    },
    zbkzj: {
      type: DataTypes.FLOAT,
      allowNull: true
    },
    zbccorpname: {
      type: DataTypes.STRING(500),
      allowNull: true,
      comment: "招标公司名称"
    },
    zbcorpcorpcode: {
      type: DataTypes.STRING(500),
      allowNull: true,
      comment: "招标公司组织机构代码"
    },
    tendercorpkindid: {
      type: DataTypes.INTEGER,
      allowNull: true,
      comment: "招标公司id"
    },
    tenderresuitenddate: {
      type: DataTypes.DATE,
      allowNull: true,
      comment: "投标结果日期"
    },
    creattime: {
      type: DataTypes.STRING(20),
      allowNull: true,
      comment: "创建时间"
    },
    isDeleted: {
      type: DataTypes.CHAR(1),
      allowNull: true,
      comment: "1=已删除 0=未删除",
      field: 'is_deleted'
    },
    createdUser: {
      type: DataTypes.BIGINT,
      allowNull: true,
      comment: "创建人",
      field: 'created_user'
    },
    createdTime: {
      type: DataTypes.DATE,
      allowNull: true,
      comment: "本系统创建时间",
      field: 'created_time'
    },
    updatedUser: {
      type: DataTypes.BIGINT,
      allowNull: true,
      comment: "修改人",
      field: 'updated_user'
    },
    updatedTime: {
      type: DataTypes.DATE,
      allowNull: true,
      comment: "修改时间",
      field: 'updated_time'
    }
  }, {
    sequelize,
    tableName: 'base_standard_projectbidinfo',
    timestamps: false,
    indexes: [
      {
        name: "PRIMARY",
        unique: true,
        using: "BTREE",
        fields: [
          { name: "id" },
        ]
      },
    ]
  });
};
